<form id="userForm">
    <input type="hidden" name="roleId" th:value="${role?.roleId}">
    <div class="form-group row">
        <label for="name" class="col-sm-2 col-form-label">角色名称</label>
        <div class="col-sm-10">
            <input type="text" th:value="${role?.name}"
                   name="name" class="form-control" id="name"
                   placeholder="请填写角色名称" required>
            <div class="invalid-feedback">请填写角色名称</div>
        </div>
    </div>
    <div class="form-group row">
        <label for="description" class="col-sm-2 col-form-label">角色描述</label>
        <div class="col-sm-10">
            <input type="text" th:value="${role?.description}" name="description" class="form-control"
                   id="description"
                   placeholder="请填写角色描述" required>
            <div class="invalid-feedback">请填写角色描述</div>
        </div>
    </div>
</form>